1. Field of the Invention
The present invention relates to the modeling of membership functions for obtaining an optimum inference value through automatic adjustment of the membership functions in a system for controlling a controlled object using a fuzzy inference method. In the modeling process, the characteristics of the controlled object are represented by one or more inference rules and membership functions.
2. Description of the Background Art
Fuzzy logic or fuzzy inference theory has been applied as an alternative to traditional expert systems that employ precise or "crisp" Boolean logic-based rules to the solution of problems involving judgment or control. Where the problems are complex and cannot be readily solved in accordance with the rigid principles of bilevel logic, the flexibility of fuzzy logic offers significant advantages in processing time and accuracy.
The theory of fuzzy logic has been published widely and is conveniently summarized in "Fuzzy Logic Simplifies Complex Control Problems" by Tom Williams, Computer Design magazine, pp 90-102 (March 1991).
In brief, however, the application of the theory requires the establishment of a set of rules conventionally referred to as "control rules", "inference rules" or "production rules" that represent the experience and know-how of an expert in the particular field in which a problem to be solved exists. The inference rules are represented in the form of IF . . . (a conditional part or antecedent part) . . . THEN . . . (a conclusion part or consequent part). This is conventionally referred to as an "If . . . Then" format. A large number of rules typically are assembled in an application rule base to adequately represent the variations that may be encountered by the application.
In addition, "membership functions" are defined for the "conditional parts" and the "conclusion parts". Specifically, variables in each of the parts are defined as fuzzy values or "labels" comprising relative word descriptions (typically adjectives), rather than precise numerical values. The set of values may comprise several different "levels" within a range that extends, for example, from "high" to "medium" to "low" in the case of a height variable. Each level will rely on a precise mapping of numerical input values to degrees of membership and will contain varying degrees of membership. For example, a collection of different levels of height from "high" to "low" may be assigned numerical values between 0 and 1. The collection of different levels is called a "fuzzy set" and the function of corresponding different height levels to numerical values is reflected by the "membership" function. Conveniently, the set may be represented by a geometric form, such as a triangle, bell, trapezoid and the like.
Then, in the fuzzy inference control procedure, the inference control is carried out in several steps. First, a determination is made of the conformity with each of the input "labels" in the "conditional part" according to the inference rules. Second, a determination is made of conformity with the entire "conditional part" according to the inference rules. Third, the membership functions of the control variables in the "conclusion part" are corrected on the basis of the conformity with the entire "condition part" according to the inference rules. Finally, a control variable is determined on an overall basis, i.e., made crisp, from the membership functions of the control variables obtained according to the inference rules. The method of determining the control variable, i.e., obtaining a crisp value, is based on any of several processes, including the center of gravity process, the area process and the maximum height process.
The fuzzy inference rules and membership functions represent the knowledge of experts who are familiar with the characteristics of a complicated controlled object including non-linear elements, e.g. the temperature control of a plastic molding machine and the compounding control of chemicals, which are difficult to describe using mathematical models in a control theory. The fuzzy logic system employs a computer to perform the inference rule and membership function processing and thereby achieve expert-level inference.
FIG. 7 shows the configuration diagram of a conventional fuzzy logic device, wherein numeral 1 indicates data input means for fetching information from a system to be controlled, 2 indicates fuzzy inference operation means for making fuzzy inferences based on the input data to the data input means, 3 indicates a data output means for outputting the inference result of the fuzzy inference operation means 2, 4 indicates an inference rule storage means for storing inference rules employed in the fuzzy inference operation means 2, and 5 is a membership function storage means for storing the shape data of the membership functions.
In the conventional fuzzy inference device constructed as described above, the relationships between input data x1, x2, . . . xn from the data input means 1 and output data y output from the data output means 3 are described by inference rules in the "If . . . Then" format. For example, when the input variables are x1 and x2, a plurality of inference rules, such as the following, are stored beforehand in the inference rule storage means 4: EQU R1: if (x1 is A11) and (x2 is A12) then (y is B1) EQU R2: if (x1 is A21) and (x2 is A22) then (y is B2)
A11 to A22, B1 and B2 are labels representing the membership functions of the inputs and outputs employed to describe the inference rules Assuming that real values x1.sup.0 and x2.sup.0 are entered into the data input means 1, inference is made in the fuzzy inference operation means 2 as shown in FIG. 8.
First, the fuzzy inference operation means 2 reads inference rules needed for the inference from the inference rule storage means 4 and relevant membership functions from the membership function storage means 5. Fuzzy inference operation means 2 then calculates the conformities W1, W2 of the condition part with each inference rule as shown in FIG. 8. This calculation may be indicated by the following mathematical expressions (1) and (2): EQU W1=A11(x1.sup.0)a12(x2.sup.0) (1) EQU W2=A21(x1.sup.0)A22(x2.sup.0) (2)
where indicates a minimum (AND) operation i.e. selection of the smallest value.
The fuzzy inference operation means 2 then finds the output values B1' and B2' of each inference rule according. to the following mathematical expressions (3), (4): EQU B1'=W1B1 (3) EQU B2'=W2B2 (4)
and obtains an inference result B0 according to the following expression: EQU B0=B1'B2'
where indicates a maximum (OR) operation, i.e., selection of the largest value.
In practice, this inference result B0 has an inference result value comprising a weighted average (center of gravity) y0. This value is calculated by means of the weight B(y) of an element y in a trapezoid set.
If the inference result value y0, found according to the above process, is undesirable to stabilize the object system, the membership functions such as A11 to A22 or B1, B2 may be slightly shifted. Then, calculations will be made according to the mathematical expressions (1) to (4), whereby an inference result value y0' slightly different from y0 can be found.
For example, the membership function A21 in FIG. 8 can be defined as: EQU A21=(a, 0/b, 1/c, 0)
employing the X coordinates a, c and y coordinate 0 of the base and the X coordinate b and Y coordinate 1 of the vertex. To shift this membership function by an amount k, set: EQU A21'=(a-k, 0/b-k, 1/c-k, 0)
This new function is not shown in FIG. 8 but would be understood by one of ordinary skill in the art.
Conventionally, a correction of the membership functions provides the inference result value which ensures stable control of the system. However, in the known modeling method, it takes time during a modeling operation to consider how to change which membership functions and to make a compilation for converting the redescribed inference rules and membership functions into a knowledge base that the fuzzy inference operation means can understand. Such modeling operation is illustrated in FIG. 9. There, in steps 2-1 and 2-2, the user describes inference rules for fuzzy control using a membership function editor and an inference rule editor. The membership functions and inference rules described by the membership function description means and inference rule description means are transmitted to the fuzzy inference operation means employing an inference rule compiler, in step 2-3. Considerable time is thus consumed for reinference, e.g. time to make a conversion into the knowledge base in step 2-4, time for the fuzzy inference operation means to read the knowledge base according to step 2-5, and time to store the knowledge base into the internal memory. Further, if the inference result found is rather good but subtly different from an expected inference value, it is very difficult to Judge how to adjust which membership functions and the judgement must therefore depend on trial and error.